/* 
 * Author: vdaras
 */

#ifndef ACTIONLISTENER_H
#define	ACTIONLISTENER_H

namespace gui
{

class Component;

/**
 * Interface that should be implemented by any class that wishes to listen
 * for events from a ui Component. IMPORTANT, if an Action Listener is destroyed
 * then it has to detach itself from each Component it's listening to!
 */

class ActionListener
{

public:
    ActionListener();


    virtual ~ActionListener();


    /**
     * This pure virtual function is called when an event is fired from a
     * a component this listener is listening to.
     *
     * @param sender
     */

    virtual void ActionPerformed(Component *sender) = 0;
};

};

#endif	/* ACTIONLISTENER_H */

